package com.cqjtu.graduation.service.impl;

import com.cqjtu.graduation.dao.FoodTypeDAO;
import com.cqjtu.graduation.entity.FoodTypeDO;
import com.cqjtu.graduation.service.FoodTypeDOService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class FoodTypeDOServiceImpl implements FoodTypeDOService {
    @Autowired
    private FoodTypeDAO foodTypeDAO;

    @Override
    public List<FoodTypeDO> listFoodTypeInfo(FoodTypeDO foodTypeDO) {
        return foodTypeDAO.listFoodTypeInfo(foodTypeDO);
    }

    @Override
    public void saveFoodTypeInfo(FoodTypeDO foodTypeDO) {
        foodTypeDAO.saveFoodTypeInfo(foodTypeDO);
    }

    @Override
    public void updataFoodTypeInfo(FoodTypeDO foodTypeDO) {
        foodTypeDAO.updataFoodTypeInfo(foodTypeDO);
    }

    @Override
    public void deleteFoodTypeInfo(Integer id) {
        foodTypeDAO.deleteFoodTypeInfo(id);
    }

    @Override
    public FoodTypeDO findOneFoodTypeInfo(Integer id) {
        return foodTypeDAO.findOneFoodTypeInfo(id);
    }

    @Override
    public List<FoodTypeDO> findAllFoodTypeInfo() {
        return foodTypeDAO.findAllFoodTypeInfo();
    }

    @Override
    public Long countFoodTypeDO() {
        return foodTypeDAO.countFoodType();
    }
}
